/* Federal University of Minas Gerais (UFMG)
 * Software Engineering Laboratory (LabSoft)
 * SimulES-SPL Project
 */

package br.ufmg.dcc.simulesspl.model;

import java.util.List;

import org.junit.Test;

import br.ufmg.dcc.simulesspl.model.ProjectCard;
import static org.hamcrest.CoreMatchers.*;
import static org.hamcrest.number.OrderingComparison.*;
import static org.junit.Assert.assertThat;

/**
 * 
 * @author Patrick Prado
 * 
 *         Testes das propriedades da classe CardProject
 */

public class ProjectCardTest {

	@Test
	public void generationOfCardsShouldReturnValidCards() {
		
		List<ProjectCard> cards = ProjectCard.create(10);
		
		assertThat(cards.size(), equalTo(10));
		
		for(ProjectCard card : cards) {
			assertThat(card.getBudget(), allOf(greaterThanOrEqualTo(2), lessThanOrEqualTo(5)));
			assertThat(card.getSize(), allOf(greaterThanOrEqualTo(20), lessThanOrEqualTo(100)));
		}
	}
}
